package com.easylinkin.linkappapi.circuit.service;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.easylinkin.linkappapi.circuit.dto.AlarmTypeCount;
import com.easylinkin.linkappapi.circuit.dto.RailGiveAlarmTypeConfigEnum;
import com.easylinkin.linkappapi.circuit.dto.RailGiveSystemAlarmDTO;
import com.easylinkin.linkappapi.circuit.entity.RailGiveSystemAlarm;
import com.easylinkin.linkappapi.circuit.vo.RailGiveSystemAlarmVO;
import com.easylinkin.linkappapi.config.entity.SysDictItem;
import com.easylinkin.linkappapi.openapi.dto.DatapushDTO;

import java.util.Date;
import java.util.List;
import java.util.Map;

public interface IRailGiveSystemAlarmService  extends   IService<RailGiveSystemAlarm>{
    /**
     *
     * @param datapushDTO 数据源
     * @param dictItem 告警项
     * @param giveAlarmTypeConfigEnum 告警类型 枚举
     */
    void datapushHandlerUseEle(DatapushDTO datapushDTO, SysDictItem dictItem, RailGiveAlarmTypeConfigEnum giveAlarmTypeConfigEnum);
    void datapushHandlerAiData(DatapushDTO datapushDTO, SysDictItem dictItem, RailGiveAlarmTypeConfigEnum giveAlarmTypeConfigEnum);

    /**
     * 分页列表查询
     * @param page
     * @param customQueryParams
     * @return
     */
    IPage<RailGiveSystemAlarmVO> selectPage(Page page, RailGiveSystemAlarmDTO customQueryParams);

    Map<String, Object> totalOldDayByLevelPieChart(String category);

    Map<String, Object> daysWeekMonthlyByLineChart(RailGiveSystemAlarmDTO dto);

    void handle(RailGiveSystemAlarmDTO dto);

    Map<String, Object> getHandleInfo(String id);

    List<AlarmTypeCount> alarmTypeCount(String category, List<String> typeList, Date startTime, Date endTime);

    List<RailGiveSystemAlarmVO> todayEleEquipmentAlarmList();

}
